package top.tungsword.webconsole.controller.main;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import top.tungsword.webconsole.controller.base.BaseController;
import top.tungsword.webconsole.interceptor.Authority;

/**
 * 功能描述: <br>
 *     探活地址
 * @Author chenji.yu
 * @Date 2020/4/14 20:03
 */
@RestController
public class StatusController extends BaseController{

    @GetMapping("/status")
    @Authority
    public String living(){
        logger.info("Web Console is running");
        return "Running.";
    }

    @GetMapping("/error/error")
    @Authority
    public String erro() throws Exception {
        throw new Exception("");
    }
}
